#include <stdio.h>
#include <string.h>
#include <stdbool.h>

bool isIsomorphic(char* s, char* t)
{
    size_t len = strlen(s);
    for(int i = 0;i < len;i++)
    {
        int n = s[i] - t[i];
        for(int j = i + 1;j < len;j++)
        {
            if(n == s[i] - t[j] && s[i] != s[j])
            {
                return false;
            }
            if(s[i] == s[j] && t[i] != t[j])
            {
                return false;
            }
        }
    }
    return true;

}

int main()
{
    char s[] = "foo";
    char t[] = "bar";
    if(isIsomorphic(s, t))
        printf("true\n");
    else
        printf("false\n");
    return 0;
}